package org.nimi317.web_gis.Enum;

import com.alibaba.fastjson2.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.EnumValue;
import com.fasterxml.jackson.annotation.JsonValue;
import lombok.AllArgsConstructor;

import java.util.Map;

/**
 * @author thunderobot
 */
@AllArgsConstructor
public enum KrigingModelEnum {
    Gaussian(0, "高斯模型"),

    Exponential(1, "指数模型"),

    Spherical(2, "球状模型");

    @EnumValue
    @JSONField
    @JsonValue
    private final int code;

    private final String value;

    public Map<?, ?> getObject() {
        return Map.of("code", code, "value", value, "desc", this.name().toLowerCase());
    }
}
